﻿using Camc.Quality.QualityAnalysis.RFormBase;
using Camc.Quality.QualityAnalysis.RFormClass;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Camc.Quality.QualityAnalysis.RFormEntity
{
   public class R爆索尺寸测量记录表 : RTableBase
    {

        public R爆索尺寸测量记录表(int serialNum, Guid rWorkStepEntityId, Guid rProcessesEntityId, int sort, string toolUsed,string recordRemark)
        {
            SerialNum = serialNum;
            RWorkStepEntityId = rWorkStepEntityId;
            RProcessesEntityId = rProcessesEntityId;
            Sort = sort;

            ToolUsed = toolUsed;
            RecordRemark = recordRemark;
        }
        public override string FormName { get; protected set; } = "爆索尺寸测量记录表";

        public override string ToolUsed_DisplayName { get; protected set; } = "所用仪器编号";
        public RRecordRequirementsEntity SetRecordRequirements(RRecordRequirementsEntity entity, string recordLocation)
        {
            entity.SetRecordLocation(recordLocation, "记录位置");
            return entity;
        }
        public RMeasuredResultEntity SetMeasuredResult(RMeasuredResultEntity entity, string firstMeasuredValues, string secondMeasuredValues, string thirdMeasuredValues)
        {
            entity.SetFirstMeasuredValues(firstMeasuredValues, "扁平（mm）");
            entity.SetSecondMeasuredValues(secondMeasuredValues, "宽度（mm）");
            entity.SetThirdMeasuredValues(thirdMeasuredValues, "总长（mm）");
            return entity;
        }
        /// <summary>
        /// 插入环境要素
        /// </summary>
        public REnvironmentEntity SetEnvironment(REnvironmentEntity entity, string temperature, string humidity)
        {
            entity.SetTemperature(temperature, "温度");
            entity.SetHumidity(humidity, "湿度");
            return entity;
        }
    }
}
